Optimal. Leaf size=145 \[ \frac {(3 b c-7 a d) (b c-a d) x}{2 b^4}-\frac {(3 b c-7 a d) (b c-a d) x^3}{6 a b^3}+\frac {d^2 x^5}{5 b^2}+\frac {(b c-a d)^2 x^5}{2 a b^2 \left (a+b x^2\right )}-\frac {\sqrt {a} (3 b c-7 a d) (b c-a d) \tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right )}{2 b^{9/2}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.09, antiderivative size = 145, normalized size of antiderivative = 1.00, number of steps
used = 5, number of rules used = 4, integrand size = 22, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.182, Rules used = {474, 470, 308,
211} \begin {gather*} -\frac {\sqrt {a} \text {ArcTan}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right ) (3 b c-7 a d) (b c-a d)}{2 b^{9/2}}+\frac {x (3 b c-7 a d) (b c-a d)}{2 b^4}-\frac {x^3 (3 b c-7 a d) (b c-a d)}{6 a b^3}+\frac {x^5 (b c-a d)^2}{2 a b^2 \left (a+b x^2\right )}+\frac {d^2 x^5}{5 b^2} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 211
Rule 308
Rule 470
Rule 474
Rubi steps
\begin {align*} \int \frac {x^4 \left (c+d x^2\right )^2}{\left (a+b x^2\right )^2} \, dx &=\frac {(b c-a d)^2 x^5}{2 a b^2 \left (a+b x^2\right )}-\frac {\int \frac {x^4 \left (-2 b^2 c^2+5 (b c-a d)^2-2 a b d^2 x^2\right )}{a+b x^2} \, dx}{2 a b^2}\\ &=\frac {d^2 x^5}{5 b^2}+\frac {(b c-a d)^2 x^5}{2 a b^2 \left (a+b x^2\right )}-\frac {((3 b c-7 a d) (b c-a d)) \int \frac {x^4}{a+b x^2} \, dx}{2 a b^2}\\ &=\frac {d^2 x^5}{5 b^2}+\frac {(b c-a d)^2 x^5}{2 a b^2 \left (a+b x^2\right )}-\frac {((3 b c-7 a d) (b c-a d)) \int \left (-\frac {a}{b^2}+\frac {x^2}{b}+\frac {a^2}{b^2 \left (a+b x^2\right )}\right ) \, dx}{2 a b^2}\\ &=\frac {(3 b c-7 a d) (b c-a d) x}{2 b^4}-\frac {(3 b c-7 a d) (b c-a d) x^3}{6 a b^3}+\frac {d^2 x^5}{5 b^2}+\frac {(b c-a d)^2 x^5}{2 a b^2 \left (a+b x^2\right )}-\frac {(a (3 b c-7 a d) (b c-a d)) \int \frac {1}{a+b x^2} \, dx}{2 b^4}\\ &=\frac {(3 b c-7 a d) (b c-a d) x}{2 b^4}-\frac {(3 b c-7 a d) (b c-a d) x^3}{6 a b^3}+\frac {d^2 x^5}{5 b^2}+\frac {(b c-a d)^2 x^5}{2 a b^2 \left (a+b x^2\right )}-\frac {\sqrt {a} (3 b c-7 a d) (b c-a d) \tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right )}{2 b^{9/2}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.07, size = 138, normalized size = 0.95 \begin {gather*} \frac {\left (b^2 c^2-4 a b c d+3 a^2 d^2\right ) x}{b^4}+\frac {2 d (b c-a d) x^3}{3 b^3}+\frac {d^2 x^5}{5 b^2}+\frac {a (b c-a d)^2 x}{2 b^4 \left (a+b x^2\right )}-\frac {\sqrt {a} \left (3 b^2 c^2-10 a b c d+7 a^2 d^2\right ) \tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right )}{2 b^{9/2}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.10, size = 141, normalized size = 0.97
method | result | size |
default | \(\frac {\frac {1}{5} b^{2} x^{5} d^{2}-\frac {2}{3} a b \,d^{2} x^{3}+\frac {2}{3} b^{2} c d \,x^{3}+3 a^{2} d^{2} x -4 a b c d x +b^{2} c^{2} x}{b^{4}}-\frac {a \left (\frac {\left (-\frac {1}{2} a^{2} d^{2}+a b c d -\frac {1}{2} b^{2} c^{2}\right ) x}{b \,x^{2}+a}+\frac {\left (7 a^{2} d^{2}-10 a b c d +3 b^{2} c^{2}\right ) \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \sqrt {a b}}\right )}{b^{4}}\) | \(141\) |
risch | \(\frac {d^{2} x^{5}}{5 b^{2}}-\frac {2 a \,d^{2} x^{3}}{3 b^{3}}+\frac {2 c d \,x^{3}}{3 b^{2}}+\frac {3 a^{2} d^{2} x}{b^{4}}-\frac {4 a c d x}{b^{3}}+\frac {c^{2} x}{b^{2}}+\frac {\left (\frac {1}{2} d^{2} a^{3}-b c d \,a^{2}+\frac {1}{2} b^{2} c^{2} a \right ) x}{b^{4} \left (b \,x^{2}+a \right )}+\frac {7 \sqrt {-a b}\, \ln \left (-\sqrt {-a b}\, x -a \right ) a^{2} d^{2}}{4 b^{5}}-\frac {5 \sqrt {-a b}\, \ln \left (-\sqrt {-a b}\, x -a \right ) a c d}{2 b^{4}}+\frac {3 \sqrt {-a b}\, \ln \left (-\sqrt {-a b}\, x -a \right ) c^{2}}{4 b^{3}}-\frac {7 \sqrt {-a b}\, \ln \left (\sqrt {-a b}\, x -a \right ) a^{2} d^{2}}{4 b^{5}}+\frac {5 \sqrt {-a b}\, \ln \left (\sqrt {-a b}\, x -a \right ) a c d}{2 b^{4}}-\frac {3 \sqrt {-a b}\, \ln \left (\sqrt {-a b}\, x -a \right ) c^{2}}{4 b^{3}}\) | \(275\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.50, size = 149, normalized size = 1.03 \begin {gather*} \frac {{\left (a b^{2} c^{2} - 2 \, a^{2} b c d + a^{3} d^{2}\right )} x}{2 \, {\left (b^{5} x^{2} + a b^{4}\right )}} - \frac {{\left (3 \, a b^{2} c^{2} - 10 \, a^{2} b c d + 7 \, a^{3} d^{2}\right )} \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \, \sqrt {a b} b^{4}} + \frac {3 \, b^{2} d^{2} x^{5} + 10 \, {\left (b^{2} c d - a b d^{2}\right )} x^{3} + 15 \, {\left (b^{2} c^{2} - 4 \, a b c d + 3 \, a^{2} d^{2}\right )} x}{15 \, b^{4}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.94, size = 400, normalized size = 2.76 \begin {gather*} \left [\frac {12 \, b^{3} d^{2} x^{7} + 4 \, {\left (10 \, b^{3} c d - 7 \, a b^{2} d^{2}\right )} x^{5} + 20 \, {\left (3 \, b^{3} c^{2} - 10 \, a b^{2} c d + 7 \, a^{2} b d^{2}\right )} x^{3} + 15 \, {\left (3 \, a b^{2} c^{2} - 10 \, a^{2} b c d + 7 \, a^{3} d^{2} + {\left (3 \, b^{3} c^{2} - 10 \, a b^{2} c d + 7 \, a^{2} b d^{2}\right )} x^{2}\right )} \sqrt {-\frac {a}{b}} \log \left (\frac {b x^{2} - 2 \, b x \sqrt {-\frac {a}{b}} - a}{b x^{2} + a}\right ) + 30 \, {\left (3 \, a b^{2} c^{2} - 10 \, a^{2} b c d + 7 \, a^{3} d^{2}\right )} x}{60 \, {\left (b^{5} x^{2} + a b^{4}\right )}}, \frac {6 \, b^{3} d^{2} x^{7} + 2 \, {\left (10 \, b^{3} c d - 7 \, a b^{2} d^{2}\right )} x^{5} + 10 \, {\left (3 \, b^{3} c^{2} - 10 \, a b^{2} c d + 7 \, a^{2} b d^{2}\right )} x^{3} - 15 \, {\left (3 \, a b^{2} c^{2} - 10 \, a^{2} b c d + 7 \, a^{3} d^{2} + {\left (3 \, b^{3} c^{2} - 10 \, a b^{2} c d + 7 \, a^{2} b d^{2}\right )} x^{2}\right )} \sqrt {\frac {a}{b}} \arctan \left (\frac {b x \sqrt {\frac {a}{b}}}{a}\right ) + 15 \, {\left (3 \, a b^{2} c^{2} - 10 \, a^{2} b c d + 7 \, a^{3} d^{2}\right )} x}{30 \, {\left (b^{5} x^{2} + a b^{4}\right )}}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 286 vs.
\(2 (133) = 266\).
time = 0.55, size = 286, normalized size = 1.97 \begin {gather*} x^{3} \left (- \frac {2 a d^{2}}{3 b^{3}} + \frac {2 c d}{3 b^{2}}\right ) + x \left (\frac {3 a^{2} d^{2}}{b^{4}} - \frac {4 a c d}{b^{3}} + \frac {c^{2}}{b^{2}}\right ) + \frac {x \left (a^{3} d^{2} - 2 a^{2} b c d + a b^{2} c^{2}\right )}{2 a b^{4} + 2 b^{5} x^{2}} + \frac {\sqrt {- \frac {a}{b^{9}}} \left (a d - b c\right ) \left (7 a d - 3 b c\right ) \log {\left (- \frac {b^{4} \sqrt {- \frac {a}{b^{9}}} \left (a d - b c\right ) \left (7 a d - 3 b c\right )}{7 a^{2} d^{2} - 10 a b c d + 3 b^{2} c^{2}} + x \right )}}{4} - \frac {\sqrt {- \frac {a}{b^{9}}} \left (a d - b c\right ) \left (7 a d - 3 b c\right ) \log {\left (\frac {b^{4} \sqrt {- \frac {a}{b^{9}}} \left (a d - b c\right ) \left (7 a d - 3 b c\right )}{7 a^{2} d^{2} - 10 a b c d + 3 b^{2} c^{2}} + x \right )}}{4} + \frac {d^{2} x^{5}}{5 b^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 1.34, size = 156, normalized size = 1.08 \begin {gather*} -\frac {{\left (3 \, a b^{2} c^{2} - 10 \, a^{2} b c d + 7 \, a^{3} d^{2}\right )} \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \, \sqrt {a b} b^{4}} + \frac {a b^{2} c^{2} x - 2 \, a^{2} b c d x + a^{3} d^{2} x}{2 \, {\left (b x^{2} + a\right )} b^{4}} + \frac {3 \, b^{8} d^{2} x^{5} + 10 \, b^{8} c d x^{3} - 10 \, a b^{7} d^{2} x^{3} + 15 \, b^{8} c^{2} x - 60 \, a b^{7} c d x + 45 \, a^{2} b^{6} d^{2} x}{15 \, b^{10}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.10, size = 200, normalized size = 1.38 \begin {gather*} x\,\left (\frac {c^2}{b^2}+\frac {2\,a\,\left (\frac {2\,a\,d^2}{b^3}-\frac {2\,c\,d}{b^2}\right )}{b}-\frac {a^2\,d^2}{b^4}\right )-x^3\,\left (\frac {2\,a\,d^2}{3\,b^3}-\frac {2\,c\,d}{3\,b^2}\right )+\frac {d^2\,x^5}{5\,b^2}+\frac {x\,\left (\frac {a^3\,d^2}{2}-a^2\,b\,c\,d+\frac {a\,b^2\,c^2}{2}\right )}{b^5\,x^2+a\,b^4}-\frac {\sqrt {a}\,\mathrm {atan}\left (\frac {\sqrt {a}\,\sqrt {b}\,x\,\left (a\,d-b\,c\right )\,\left (7\,a\,d-3\,b\,c\right )}{7\,a^3\,d^2-10\,a^2\,b\,c\,d+3\,a\,b^2\,c^2}\right )\,\left (a\,d-b\,c\right )\,\left (7\,a\,d-3\,b\,c\right )}{2\,b^{9/2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________